home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Night Owl 6
/
Night Owl's Shareware - PDSI-006 - Night Owl Corp (1990).iso
/
027a
/
clipmen.zip
/
README
< prev
Wrap
Text File
|
1991-11-15
|
4KB
|
92 lines
You should now have three files. They are:
README (the file you are reading now)
MENU.PRG (source code)
MENU.OBJ (object form of above)
They were created by me, Ron Laska, for use in my day to day programming tasks.
They have been of great service to me and I hope they can do the same for you.
I have included the source code for those of you who might want or need to
modify the functions. If you feel that these functions have been of any value
to you, I would greatly appreciate a small donation ($ 5.00). If these
functions are useless pieces of crap, I would like to know that also.
Please send any donations/correspondance to:
Ronald Laska
1690 N. 1st Ave. Apt. #2
Melrose Park, IL 60160
If you have any comments or improvements to the functions you can send a
message to me on the EXEC-PC bulletin board under the name of MAP FINANCIAL.
The file MENU.PRG contains six functions. They are described below.
- FUNCTION messmenu( nTOP, nLEFT, nBOTTOM, nRIGHT, aCHOICES, [lESCTOEXIT],;
[cBOXCOLOR], [cITEMSCOLOR], [cHIGHCOLOR] )
This function will display a scrolling menu with a message tacked on
underneath the menu box. Up and Down arrow keys move through the menu
item by item. PageUp and PageDown move through the menu by pages. Home
will take you to the top. End will take you to the bottom. Any
alphanumeric key will position the highlight bar on the item with a
matching first character. If none match, the highlight will not move.
The array of choices must be set up as in the following example:
LOCAL aCHOICES:={{"ITEM1","MESSAGE1"}
{"ITEM2","MESSAGE2"}
.
.
.
{"ITEMn","MESSAGEn"}
}
An item is selected by pressing the enter key. The function will return
the element number of the item selected.
- FUNCTION checkmenu( nTOP, nLEFT, nBOTTOM, nRIGHT, aCHOICES, [cBOXCOLOR],;
[cITEMSCOLOR], [cHIGHCOLOR] )
This function will display a 'Check-Box' type menu. The same movement keys
are active as in "messmenu." 'Checking' an item is done through the enter
key. The function will return an array containing the element numbers
of the items selected.
- FUNCTION newscrollbar( nTOP, nCOLUMN, nBOTTOM, cCOLOR, nSTARTPOS )
This function is used in conjunction with 'displayscroll' and
'updatescroll' to display a vertical scroll bar. This function must be
called before any calls to the other functions can be made. The function
will return an array containing information that is needed by the other
functions.
- FUNCTION displayscroll( aBARARRAY )
This function draws the scroll bar on the screen. This function should
only be called once usually right after a call to newscrollbar.
For example:
displayscroll(newscrollbar(0,79,24,"GR+/R",1)
- FUNCTION updatescroll( aBARARRAY, nCURRENTPOS, nTOTAL, lFORCEUPDATE )
This function is used to update the scroll bar. For examples of its use
see the source code.
- FUNCTION boxshadow( nTOP, nLEFT, nBOTTOM, nRIGHT )
This function draws a drop-shadow around the lower right corner of an
object for that oh so popular '3-D' effect.
*** REMEMBER - If you drink, don't drill.